package com.frxuexi.lib_base.room

import androidx.room.Dao
import androidx.room.Delete
import androidx.room.Insert
import androidx.room.OnConflictStrategy
import androidx.room.Query

@Dao
interface ZanDao {
    @Insert(onConflict = OnConflictStrategy.REPLACE)
    fun addZan(zanEntity: ZanEntity):Long

    @Query("select * from zan where id=:id")
    fun isZan(id:Int):ZanEntity

    @Delete
    fun cancelZan(entity: ZanEntity):Int
}